package com.ecds.monitor;

import java.sql.Connection;
import java.sql.SQLException;

import com.ecds.monitor.helper.ConnUtil;
import com.ecds.monitor.helper.SystemHelper;

public class ConnectDBTest {
	public static void getConn(){
		Connection conn = null;
		try {
			conn = ConnUtil.getConn();
		} catch (Exception e) {
			if (conn != null) {
				try {
					conn.close();
				} catch (SQLException e1) {
					e1.printStackTrace();
				}
			}
			e.printStackTrace();
			String message = MainServer.rb
					.getString("monitoring.databese.exception");
			SystemHelper.testSendSMS(message);
		}
	}
}
